<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
<head>
    <th:block th:include="include :: header('修改生成信息')"/>
    <th:block th:include="include :: select2-css" />
    <script type="text/css">
        .select-table table{table-layout: fixed;}
        .table>thead>tr>th{text-align: center;}
        .select-table
        .table td{overflow: hidden;
                  text-overflow: ellipsis;
                   white-space: nowrap;
                   }
        .form-control{padding: 3px 6px 4px;height:30px}
        .icheckbox-blue{top:0px;left: 6px;}
        .form-control.select2-hidden-accessible{position: static!important; }
        .select-table table label.error{position: inherit; }
        select + label.error{ z-index:1;right:40px}
    </script>
</head>
<body class="gray-bg" style="font:14px Helvetica Neue, Helvetica, PingFang SC, 微软雅黑,Tahoma, Arial,sans-serif !important">
    <section class="section-content">
        <div class="col-xs-12">
            <div class="ibox float-e-margins">
                <div class="ibox-content" style="border-style: none">
                    <div class="nav-tabs-custom">
                        <ul class="nav nav-tabs">
                            <li><a href="#tab-basic" data-toggle="tab" aria-expanded="false">基本信息</a> </li>
                            <li class="active"><a href="#tab-field" data-toggle="tab" aria-expanded="false">字段信息</a> </li>
                            <li><a href="#tab-gen" data-toggle="tab" aria-expanded="false">生成信息</a> </li>
                            <li class="pull-right header"><i class="fa fa-code"></i>生成配置</li>
                        </ul>
                        <form id="form-gen-edit" class="form-horizontal" th:object="${table}">
                            <input name="tableId" type="hidden" th:field="*{tableId}" />
                            <div class="tab-content">
                                <!--基本信息-->
                                <div class="tab-pane" id="tab-basic">
                                    <div class="row mt20">
                                        <div class="form-group">
                                            <label class="col-sm-4 control-label is-required">表名称:</label>
                                            <div class="col-sm-8">
                                                <input name="tableName" class="form-control" type="text" placeholder="请输入表名称" maxlength="200" th:filed="*{tableName}" required>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="col-sm-6">
                                        <div class="form-group">
                                            <label class="col-sm-4 control-label is-required">表描述:</label>
                                            <div class="col-sm-8">
                                                <input name="tableComment" class="form-control" type="text" placeholder="请输入表描述" maxlength="500" th:field="*{tableComment}" required>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-sm-6">
                                        <div class="form-group">
                                            <label class="col-sm-4 control-label is-required">实体类名称:</label>
                                            <div class="col-sm-8">
                                                <input name="className" class="form-control" type="text" placeholder="请输入实体类名称" maxlength="100" th:field="*{className}" required>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="col-sm-6">
                                        <div class="form-group">
                                            <label class="col-sm-4 control-label is-required">作者:</label>
                                            <div class="col-sm-8">
                                                <input name="functionAuthor" class="form-control" type="text" placeholder="请输入作者" maxlength="50" th:field="*{functionAuthor}" required>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <div class="row">
                                    <div class="col-sm-12">
                                        <div class="form-group">
                                            <label class="col-xs-2 control-label">备注:</label>
                                            <div class="col-xs-10">
                                                <textarea name="remark" maxlength="500" class="form-control" rows="3"></textarea>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>

                            <!--字段信息-->
                            <div class="tab-pane active" id="tab-field">
                                <div class="select-table table-striped" style="margin-top:0px;padding-top: 0px;padding-bottom: 0px; ">
                                    <table id="bootstrap-table" data-use-row-attr-func="true" data-reorderable-rows="true"></table>
                                </div>
                            </div>
                            <!--生成信息-->
                            <div class="tab-pane" id="tab-gen">
                                <div class="row mt20">
                                    <div class="col-sm-6">
                                        <div class="form-group">
                                            <label class="col-sm-4 control-label is-required">生成模板:</label>
                                            <div class="col-sm-8">
                                                <select class="form-control" id="tplCategory" name="tplCategory" style="width: 100%">
                                                       <option value="curd" th:field="*{tplCategory}">单表(增删改查)</option>
                                                       <option value="tree" th:field="*{tplCategory}">树表(增删改查)</option>
                                                       <option value="sub" th:field="*{tplCategory}">主子表(增删改查)</option>
                                                </select>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <div class="col-sm-6">
                                    <div class="form-group">
                                        <label class="col-sm-4 control-label is-required" title="生成在哪个Java包下,例如com.yoyo.project.system">生成包路径：<i class="fa fa-question-circle-o"></i> </label>
                                        <div class="col-sm-8">
                                            <input name="packageName" class="form-control" type="text" placeholder="请输入生成包路径" maxlength="100" th:field="*{packageName}" required>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-6">
                                    <div class="form-group">

                                    </div>
                                </div>
                            </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </section>
</body>
</html>